package com.demo.service.impl;

import java.util.Date;
import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.demo.entity.User;
import com.demo.entity.UserBase;
import com.demo.mapper.UserBaseMapper;
import com.demo.mapper.UserMapper;
import com.demo.service.IUserServices;
import com.demo.util.MD5;

@Service
public class UserService implements IUserServices {

	@Autowired
	private UserMapper userMapper;

	@Override
	public List<User>  selectUserList() throws Exception {
		return userMapper.selectUserList();
	}

	@Override
	public int save(User userBase) {
		Date now = new Date();
		return userMapper.insertSelective(userBase);
	}

	@Override
	public int delete() {
		 
		return userMapper.delete();
	}

}
